package Year21_Month10.day1022;

public class Solution {
    public ListNode removeElements(ListNode head, int val)
    {
        if (head == null) {
            return head;
        }
        head.next = removeElements(head.next, val);
        return head.val == val ? head.next : head;
    }
}
